#include <bits/stdc++.h>

using namespace std;

int xt,yt,xm,ym,cnt;
bool ishorse[30][30];
int xx[] = {1,1,-1,-1,2,2,-2,-2};
int yy[] = {-2,2,-2,2,-1,1,-1,1};
long long dp[30][30];
long long dfs(int x,int y){
    if(dp[x][y]!=-1)return dp[x][y];
    if(ishorse[x][y])return dp[x][y]=0;
    if(x==0||y==0)return dp[x][y] = 1;
    long long a = dfs(x-1,y);
    long long b = dfs(x,y-1);
    return dp[x][y] = a+b;
}
int main()
{
    cin>>xt>>yt>>xm>>ym;
    ishorse[xm][ym]=1;
    for(int i=0;i<8;i++){
        if((xm+xx[i])>=0&&(xm+xx[i])<=xt&&(ym+yy[i])<=yt&&(ym+yy[i])>=0)
        ishorse[xm+xx[i]][ym+yy[i]]=1;
    }
    memset(dp,-1,sizeof(dp));
    cout<<dfs(xt,yt);
    return 0;
}
